(function() {

	var appModule = angular.module('tracecashModule');

	appModule.controller('ReportCtrl', ['$scope', '$rootScope', '$http', function($scope, $rootScope, $http) {
		$scope.generate = function() {
			$scope.isLoading = true;
			$http.post($rootScope.REST_PATH + '/report/generate/', $scope.reportSearchOptions).success(function(data) {
				$scope.isLoading = false;
				$scope.message = data;
			});
		};
	}]);

})();